package string;

public class StartsWithDemo {
    public static void main(String[] args) {
        String a= "www.baodu.cn";
        boolean b =a.startsWith("www")&&a.endsWith("cn")?true:false;
        System.out.println(b);

        char c = a.charAt(4);
        System.out.println(c);


    }
}
